import request from "@/utils/request";

/**
 * 新增标准代码分类
 * @param data
 * @returns {Promise<AxiosResponse<any>>}
 */
export function createDictType(data) {
    return request({
        url: '/standardCode/type/create',
        method: 'post',
        data
    });
}

/**
 * 删除标准代码分类
 * @param id
 * @returns {Promise<AxiosResponse<any>>}
 */
export function removeDictType(id) {
    return request({
        url: '/standardCode/type/delete/' + id,
        method: 'get'
    });
}

/**
 * 更新标准代码分类
 * @param data
 * @returns {Promise<AxiosResponse<any>>}
 */
export function updateDictType(data) {
    return request({
        url: '/standardCode/type/update',
        method: 'post',
        data
    });
}

/**
 * 分页查询
 * @param params
 * @returns {Promise<AxiosResponse<any>>}
 */
export function queryPage(params) {
    return request({
        url: '/standardCode/type/queryPage',
        method: 'get',
        params
    });
}
